//Newsimg
const router = require('koa-router')()

router.prefix('/newsimg')

//根据collect_id=>newsid获取newsimg详情
router.get('/single', async (ctx, next) => {
    let newsid = ctx.request.body.newsid;
    let result = await ctx.db.EXCUTE('SELECT * FROM newsimg WHERE newsid=' + newsid);
    ctx.body = {
        code: 200,
        data: result
    }
})

module.exports = router